﻿CREATE PROCEDURE admin.s_InitCollectionFilterGroups AS

TRUNCATE TABLE t_CollectionFilterGroups
DECLARE @DPD int,@DPD_ int SELECT @DPD = 0,@DPD_ = 1
DECLARE @CID int
WHILE @DPD <= 300 BEGIN
	SET @CID = 1
	WHILE @CID < 6 BEGIN
		INSERT INTO t_CollectionFilterGroups(CompanyID,DPD,Filter)
		VALUES(@CID,@DPD,dbo.Collection_GroupFilter(@CID,@DPD))
		SET @CID=@CID+1
	END
	SET @DPD=@DPD+@DPD_
END

SELECT * FROM t_CollectionFilterGroups

